<%@ page contentType="text/html;charset=UTF-8" %>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
<%@ taglib tagdir="/WEB-INF/tags/simpletable" prefix="simpletable"%>
<%@ include file="/commons/taglibs.jsp" %>
 
 
<jsFileName><!--js/pageJS/module/page_moduleManage.js--></jsFileName>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">

<s:form name="moduleListFromName" id="moduleListFromId" method="post" action="modfun/list.do">
	<s:hidden id="mdid" name="mdid"/>
	<s:hidden id="pid" name="pid"/>
	<div class="trans_operate_box clearfix">
		<div class="operate_btns">
			<a class="btn_long" href="javascript:void(0)" title="新建同级模块" onClick="Ext.milan.pagejs.module.page_modulemanage.addSame('moduleListFromId')">新建模块</a>
			<a class="btn_long" href="javascript:void(0)" title="新建子模块" onClick="Ext.milan.pagejs.module.page_modulemanage.addSubType('moduleListFromId');">新建子模块</a>
			<a class="btn_long" href="javascript:void(0)"  title="编辑本模块" onClick="Ext.milan.pagejs.module.page_modulemanage.modifySelfType('moduleListFromId');">编辑本模块</a>
			<a class="btn_long" href="javascript:void(0)" title="删除本模块" onClick="Ext.milan.pagejs.module.page_modulemanage.deleteSelfType('moduleListFromId');">删除本模块</a>
			<a class="btn_long" href="javascript:void(0)" title="添加功能" onClick="Ext.milan.pagejs.module.page_modulemanage.addFunction('moduleListFromId');">添加功能</a>
			<a class="btn_long" href="javascript:void(0)" title="删除功能" onClick="Ext.milan.pagejs.module.page_modulemanage.deleteBatch('moduleListFromId');">删除功能</a>
	  	</div>
	</div>
	
	<table id="knowlwdgeTypeList" gridWidth="100%" width="100%" height="100%" class="dhtmlxGrid" imgpath="skins/default/images/dhtmlx/" lightnavigation="true">
		<tr>
          <th width="10%" sort="na"><input name="checkall" type="checkbox" id="checkall" onClick="Ext.milan.pagejs.module.page_modulemanage.chkAllClick(this);"  title="全选或全不选">全选</th>
          <th width="16%">功能名</th>
		  <th width="19%">功能类型</th>
		  <th width="30%">URL</th>
		  <th width="19%">操作</th>
        </tr>
        <c:forEach items="${list}" var="item" varStatus="status">
        	<tr class="grid-row-bg1">
	        	<td><input title="打勾选择该功能" name="items" id="selectCheck" type="checkbox" value="mfid=${item.mfid}&"  onClick="Ext.milan.pagejs.module.page_modulemanage.chkClick(this);"></td>
	        	<td align="left">${item.name}</td>
	        	<td align="left">
	        		<c:if test="${item.funType == '1'}">我的工作台</c:if>
					<c:if test="${item.funType == '2'}">企业工作台</c:if>
					<c:if test="${item.funType == '3'}">系统工作台</c:if>
					<c:if test="${item.funType == '4'}">权限工作台</c:if>
					<c:if test="${item.funType == '5'}">按钮功能</c:if>
	        	</td>
				<td align="left">${item.url }</td>
				<td align="left">
					<a href="#" onClick="Ext.milan.pagejs.module.page_modulemanage.deleteModFun('${item.mfid}')"><img src="skins/default/images/icons/ico-delete.gif" />删除</a>&nbsp;
				</td>
				<input type="hidden" id='dirManagerKnowledgeTypeListHasChild_34' name="dirManagerKnowledgeTypeListHasChild_34" value="false" />
	        </tr>
        </c:forEach>
	</table>
</s:form>
<script>
function onload()
{
	Milan.commonutils.checkBoxRelation('moduleListFromId', 'checkall', 'items');
}
</script>
